<?php

use Illuminate\Http\Request;
use Illuminate\Support\Facades\Route;

/*
|--------------------------------------------------------------------------
| API Routes
|--------------------------------------------------------------------------
|
| Here is where you can register API routes for your application. These
| routes are loaded by the RouteServiceProvider and all of them will
| be assigned to the "api" middleware group. Make something great!
|
*/

Route::prefix('admin')->group(function () {
    Route::prefix('index')->group( function () {
        Route::get('index', [\App\Http\Controllers\Admin\IndexController::class, 'index'])->name('index');
        Route::get('dashboard', [\App\Http\Controllers\Admin\IndexController::class, 'dashboard']);
    });
    Route::prefix('public')->group( function () {
        Route::get('login', [\App\Http\Controllers\Admin\PublicController::class, 'login']);
        Route::post('login', [\App\Http\Controllers\Admin\PublicController::class, 'login']);
    });
});
